<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<title>管理中心首页</title>
	<link rel="stylesheet" href="__PUBLIC__/admin/css/index.css" />
        <script src="__PUBLIC__/jquery-1.7.2.min.js"></script>
        <script>
            $(function(){
                $('.del').click(function(){
                    if(!confirm('确定要删除此分类?')){
                        return false;
                    }
                });
            })
        </script>
        <style type="text/css">
            table tr{height:50px;}
            table tr.t{height:25px;}
        </style>
</head>
<body>
	<div class='content'>
		<div class='t'>
			<h3>品牌列表</h3>
		</div>
		<table class='tb' >
			<tr class='t'>
				<th class="blue">品牌ID</th>
				<th class="blue">品牌名称</th>
                                <th class="blue">品牌logo</th>
				<th class="blue">操作</th>
			</tr>
                    <?php if(is_array($data)): foreach($data as $key=>$ca): ?><tr>
				<td><?php echo ($ca["bid"]); ?></td>
				<td><?php echo ($ca["name"]); ?></td>
                                <td>
                                    <?php if($ca['breed_logo'] != ''): ?><img src="__ROOT__/uploads/breed/<?php echo ($ca["breed_logo"]); ?>" width='120' height="40"/>
                                    <?php else: ?>
                                    未上传品牌logo<?php endif; ?>
                                </td>
				<td>
                                    <a href="<?php echo U('Breed/addAct',array('bid'=>$ca['bid']));?>">添加活动</a>
					<a href="<?php echo U('Breed/editShow',array('bid'=>$ca['bid']));?>">编辑</a>
					<a class="del" href="<?php echo U('Breed/del',array('bid'=>$ca['bid']));?>">删除</a>
				</td>
			</tr><?php endforeach; endif; ?>
		</table>
		
	</div>

</body>
</html>